package com.ruoyi.system.service;

import java.util.List;

import com.ruoyi.system.domain.ExportParam;
import com.ruoyi.system.domain.SalePlan;
import com.ruoyi.system.domain.SalePlanForWaybill;

import javax.servlet.http.HttpServletResponse;

/**
 * 销售计划Service接口
 * 
 * @author he
 * @date 2025-08-14
 */
public interface ISalePlanService 
{
    /**
     * 查询销售计划
     * 
     * @param id 销售计划主键
     * @return 销售计划
     */
    public SalePlan selectSalePlanById(Long id);

    /**
     * 查询销售计划列表
     * 
     * @param salePlan 销售计划
     * @return 销售计划集合
     */
    public List<SalePlan> selectSalePlanList(SalePlan salePlan);

    /**
     * 新增销售计划
     * 
     * @param salePlan 销售计划
     * @return 结果
     */
    public int insertSalePlan(SalePlan salePlan);

    /**
     * 修改销售计划
     * 
     * @param salePlan 销售计划
     * @return 结果
     */
    public int updateSalePlan(SalePlan salePlan);

    /**
     * 批量删除销售计划
     * 
     * @param ids 需要删除的销售计划主键集合
     * @return 结果
     */
    public int deleteSalePlanByIds(Long[] ids);

    /**
     * 删除销售计划信息
     * 
     * @param id 销售计划主键
     * @return 结果
     */
    public int deleteSalePlanById(Long id);

    void exportNew(HttpServletResponse response, ExportParam exportParam);

    List<SalePlanForWaybill> getPlanNameOptions(SalePlan paramName);

    List<SalePlan> selectSalePlanByCode(String code);

    List<SalePlan> selectSalePlanListByIdList(List<Long> collect);

    /**
     * 批量更新审批状态
     *
     * @param ids 需要更新的销售/采购计划主键集合
     * @param approvalState 审批状态
     * @return 结果
     */
    int updateApprovalState(List<Long> ids, Integer approvalState);
}
